Matthias Clasen [Tue, 7 May 2019 18:57:44 +0000 (18:57 +0000)]
Merge branch 'gdk-win32-unimplement-vfuncs' into 'master'
GdkSurface - Don't call unimplemented NULL set_startup_id() vfunc on Win32
See merge request GNOME/gtk!825
Matthias Clasen [Tue, 7 May 2019 18:41:22 +0000 (18:41 +0000)]
emoji chooser: Name the idle
We recently added an idle that does quite a bit of work.
It should have a name.
Sebastian Dröge [Tue, 7 May 2019 06:53:51 +0000 (09:53 +0300)]
GdkSurface - Don't call unimplemented NULL set_startup_id() vfunc on Win32
GdkSurface::set_startup_id() is NULL on Win32 and would cause a segfault
if called.
While the documentation of the main caller of set_startup_id(),
gtk_window_set_startup_id(), mentions that it's not implemented on
Windows it can still be automatically called via Glade and simply doing
nothing on Win32 is going to be less disruptive than a segfault.
Matthias Clasen [Tue, 7 May 2019 18:37:11 +0000 (18:37 +0000)]
Merge branch 'tracing' into 'master'
Tracing
See merge request GNOME/gtk!563
Matthias Clasen [Mon, 6 May 2019 20:30:20 +0000 (13:30 -0700)]
Add docs
Document the various ways to start profiling.
Matthias Clasen [Sat, 19 May 2018 19:36:00 +0000 (20:36 +0100)]
GtkApplication: Add a profiler dbus api
Implement the org.gnome.Sysprof2.Profiler D-Bus
api to let sysprof start and stop tracing at runtime,
and get the data directly, via a passed fd.
Matthias Clasen [Sat, 19 May 2018 19:35:02 +0000 (20:35 +0100)]
gsk: Add tracing to the vulkan renderer
Emit the equivalent of the cpu-time counter, as well
as pixel numbers i the inspector.
Matthias Clasen [Sat, 19 May 2018 19:25:17 +0000 (20:25 +0100)]
gsk: Add tracing to the gl renderer
Emit the equivalent of the cpu-time counter in the inspector.
Matthias Clasen [Sat, 19 May 2018 19:26:21 +0000 (20:26 +0100)]
gsk: Add some more profiler apis
Add a way to extract the start time of timers.
This will let us reuse the profiler timers for tracing.
Matthias Clasen [Sat, 19 May 2018 19:24:21 +0000 (20:24 +0100)]
frame clock: Add tracing
Emit tracing data for frames. For now, we emit the
entire frame, and the layout and paint phases. Also
emit frames-per-second.
Matthias Clasen [Sat, 19 May 2018 18:42:11 +0000 (19:42 +0100)]
Add a way to start the profiler
If SYSPROF_TRACE_FD is set in the environment,
interpret it as an fd to write profiling data
to.
If GTK_TRACE is set, write profiling data
to a file with name gtk.$PID.syscap.
Matthias Clasen [Sat, 19 May 2018 18:35:42 +0000 (19:35 +0100)]
gdk: Add a profiler
This is writing data in the capture format of sysprof,
using the SpCaptureWriter. For now, this is using a
vendored copy of libsysprof. Eventually, we want to
use the static library that sysprof provides.
Marek Kašík [Tue, 7 May 2019 16:32:36 +0000 (16:32 +0000)]
Merge branch 'cups-deprecation-warnings' into 'master'
Fix deprecation warnings when building the CUPS print backend
See merge request GNOME/gtk!739
Emmanuele Bassi [Mon, 6 May 2019 19:04:17 +0000 (20:04 +0100)]
Require CUPS >= 2.0
Drop support for versions of CUPS < 2.0, to simplify the backend code
and drop a lot of conditional blocks.
Emmanuele Bassi [Fri, 12 Apr 2019 17:00:02 +0000 (18:00 +0100)]
cups: Use non-deprecated API
The http* family of functions was deprecated after CUPS 1.7. We can
conditionally use it when built against a newer version of CUPS. The
additional parameters are taken directly from the fallback values
inside CUPS itself.
Emmanuele Bassi [Fri, 12 Apr 2019 16:58:53 +0000 (17:58 +0100)]
Detect CUPS ≥ 1.7
We support CUPS ≥ 1.2, but we use API that was introduced and deprecated
at a later point.
Timm Bäder [Tue, 7 May 2019 15:20:11 +0000 (17:20 +0200)]
gl renderer: Fix blur nodes with radius 0
Timm Bäder [Tue, 7 May 2019 15:19:58 +0000 (17:19 +0200)]
node editor: Do some simple syntax highlighting
Timm Bäder [Tue, 7 May 2019 15:19:00 +0000 (17:19 +0200)]
testsuite: Add blur node testcase
Renderers need to handle blur radius 0 as well. Currently broken in GL
and (I guess, unless it's my driver) Vulkan.
Matthias Clasen [Tue, 7 May 2019 14:57:53 +0000 (14:57 +0000)]
Fix the compiler warning, again
Matthias Clasen [Tue, 7 May 2019 04:01:21 +0000 (04:01 +0000)]
Fix a compiler warning
Matthias Clasen [Tue, 7 May 2019 03:01:40 +0000 (03:01 +0000)]
3.96
Matthias Clasen [Tue, 7 May 2019 03:26:22 +0000 (03:26 +0000)]
Mark a failing reftest as xfail
I don't know why we expect different window types
to render identically in the first place.
Matthias Clasen [Mon, 6 May 2019 23:33:13 +0000 (23:33 +0000)]
Update a11y tests
Matthias Clasen [Tue, 7 May 2019 02:20:29 +0000 (02:20 +0000)]
a11y: Stop using child-notify
This was showing up in the accessibility tests failing.
Matthias Clasen [Mon, 6 May 2019 22:20:51 +0000 (22:20 +0000)]
widget: Revert the event translation change
This is a temporary revert to make menus work
in the 3.96 release, until we land the popup
surface work and port menus to it.
Closes: https://gitlab.gnome.org/GNOME/gtk/issues/1755
Benjamin Otte [Mon, 6 May 2019 18:24:49 +0000 (18:24 +0000)]
Merge branch 'wip/headers' into 'master'
Wip/headers
See merge request GNOME/gtk!824
Benjamin Otte [Mon, 6 May 2019 18:09:52 +0000 (20:09 +0200)]
broadway: Install headers
How are we going to check a display for its broadway-ness otherwise?
Benjamin Otte [Mon, 6 May 2019 18:09:03 +0000 (20:09 +0200)]
build: Install the backend headers in the backend directories
That's where they are in the sources and we include them from other
headers. So make sure the directories match.
Piotr Drąg [Mon, 6 May 2019 16:55:40 +0000 (18:55 +0200)]
Update POTFILES.skip
Timm Bäder [Mon, 6 May 2019 15:58:55 +0000 (17:58 +0200)]
gl renderer: Fix coloring shader
We *just* pre-multiplied u_color but then didn't use its rgb values.
This fixes backdrop scale marks in Adwaita to not be white.
Timm Bäder [Mon, 6 May 2019 15:33:48 +0000 (17:33 +0200)]
gl renderer: Fix blend shader
Timm Bäder [Mon, 6 May 2019 15:33:29 +0000 (17:33 +0200)]
testsuite: Add blend-difference test case
Comparing blend nodes with mode: difference
Timm Bäder [Mon, 6 May 2019 15:26:46 +0000 (17:26 +0200)]
testsuite: Add a blend node test case
This is currently broken in the GL renderer.
Timm Bäder [Sat, 4 May 2019 07:22:01 +0000 (09:22 +0200)]
Some node editor improvements
Matthias Clasen [Mon, 6 May 2019 14:17:17 +0000 (14:17 +0000)]
Merge branch 'header-bar-leak4' into 'master'
GtkHeaderBar: Don't leak decoration layout
See merge request GNOME/gtk!822
Emmanuele Bassi [Mon, 6 May 2019 12:01:47 +0000 (12:01 +0000)]
Merge branch 'issue-1863' into 'master'
Allow setting the GtkLayoutManager type per-class
Closes #1863
See merge request GNOME/gtk!821
Emmanuele Bassi [Mon, 6 May 2019 11:15:21 +0000 (12:15 +0100)]
Make get_layout_manager_type() public
The inspector, and other tools introspecting the widget structure like
gtk-builder-tool and Glade, may very well want to access the default
layout manager used by a class, especially if there are layout
properties involved, without having a whitelist of widget/layout manager
associations.
Emmanuele Bassi [Mon, 6 May 2019 11:06:27 +0000 (12:06 +0100)]
Use gtk_widget_class_set_layout_manager_type()
Instead of manually creating the layout manager inside the instance
initialization function, we can let GtkWidget do that for us.
Guido Günther [Mon, 6 May 2019 10:55:16 +0000 (12:55 +0200)]
GtkHeaderBar: Don't leak decoration layout
Currently we leak priv->decoration_layout if the layout is set
multiple times.
Emmanuele Bassi [Mon, 6 May 2019 10:57:32 +0000 (11:57 +0100)]
Allow specifying the layout manager for a widget type
Some widgets have a well-defined layout manager created alongside their
own instance; if they do, we can handle the layout manager creation at
the GtkWidget instantiation.
Benjamin Otte [Mon, 6 May 2019 03:56:06 +0000 (05:56 +0200)]
csstokenizer: Consume the \ when encountering an error
Otherwise we infinitely end up with the error again.
Testcases added.
Matthias Clasen [Sun, 5 May 2019 20:19:13 +0000 (20:19 +0000)]
Merge branch 'simplify-tests' into 'master'
Simplify tests
See merge request GNOME/gtk!820
Matthias Clasen [Sun, 5 May 2019 15:29:24 +0000 (15:29 +0000)]
Add some tests
These test various aspects of ui file conversion.
Matthias Clasen [Sun, 5 May 2019 17:09:17 +0000 (17:09 +0000)]
builder-tool: Handle layout properties more properly
Change things so we first rewrite the whole tree,
and then simplify the rewritten tree. And look
for paramspecs for layout properties.
Matthias Clasen [Sun, 5 May 2019 15:49:28 +0000 (15:49 +0000)]
builder-tool: Stop warnings for stack rewrites
When rewriting a GtkStack from 3 to 4, we were emitting
warnings for missing child properties. Stop doing that.
Matthias Clasen [Sun, 5 May 2019 15:23:59 +0000 (15:23 +0000)]
testsuite: Add tests for ui file rewriting
Add a test script that runs
gtk4-builder-tool simplify --3to4.
No actual tests yet.
Matthias Clasen [Sun, 5 May 2019 15:21:58 +0000 (15:21 +0000)]
Fix the simplify test
The script was returning the wrong number of tests.
Matthias Clasen [Sun, 5 May 2019 14:20:04 +0000 (14:20 +0000)]
Merge branch 'focus-fixes' into 'master'
Focus fixes
See merge request GNOME/gtk!819
Piotr Drąg [Sun, 5 May 2019 14:11:04 +0000 (16:11 +0200)]
Update POTFILES.skip
Matthias Clasen [Sun, 5 May 2019 06:57:21 +0000 (06:57 +0000)]
Merge branch 'builder-tool-fixes' into 'master'
Builder tool fixes
See merge request GNOME/gtk!817
Matthias Clasen [Sun, 5 May 2019 06:41:31 +0000 (06:41 +0000)]
Merge branch 'emoji-chooser-fixes' into 'master'
Emoji chooser fixes
See merge request GNOME/gtk!816
Matthias Clasen [Sat, 4 May 2019 15:59:08 +0000 (15:59 +0000)]
builder-tool: Handle default values changing
The default value of GtkWidget::visible changed
from FALSE to TRUE from GTK 3 to 4. Make --3to4
deal with this by ensuring the visible property
is explicitly set, before simplifying.
Benjamin Otte [Sun, 5 May 2019 05:40:54 +0000 (05:40 +0000)]
Merge branch 'wip/otte/nodeeditor2' into 'master'
Use a text based format for render node files
See merge request GNOME/gtk!815
Timm Bäder [Sat, 4 May 2019 08:13:30 +0000 (10:13 +0200)]
gl renderer: Reset opacity when offscreen-rendering crossfade nodes
A pattern emerges...
Benjamin Otte [Thu, 2 May 2019 18:09:31 +0000 (20:09 +0200)]
testsuite: Add serialize test for debug node
Benjamin Otte [Sat, 9 Mar 2019 13:55:17 +0000 (14:55 +0100)]
node-editor: Add renderings with alternative renderers
That's pretty rough around the edges, but it mostly works.
Apart from sizing, screw listbox sizing.
Benjamin Otte [Thu, 2 May 2019 00:57:23 +0000 (02:57 +0200)]
gsk: Export gsk_vulkan_renderer_new()
Benjamin Otte [Thu, 2 May 2019 00:46:23 +0000 (02:46 +0200)]
gsk: Export gsk_broadway_renderer_new()
... when broadway is enabled.
Benjamin Otte [Thu, 2 May 2019 00:13:16 +0000 (02:13 +0200)]
gsk: Export gsk_gl_renderer_new()
Benjamin Otte [Wed, 1 May 2019 21:58:57 +0000 (23:58 +0200)]
gsk: Export Cairo renderer
Benjamin Otte [Wed, 1 May 2019 13:29:38 +0000 (15:29 +0200)]
testsuite: Add rounded-rect parsing test
Benjamin Otte [Tue, 12 Mar 2019 14:05:25 +0000 (15:05 +0100)]
Add gtk4-node-editor
It's meant to be a little editor for render nodes so we can do testing
with it.
Benjamin Otte [Sat, 27 Apr 2019 07:03:51 +0000 (09:03 +0200)]
rendernode: Parse and print blend nodes properly
Timm Bäder [Wed, 24 Apr 2019 06:00:04 +0000 (08:00 +0200)]
testsuite: Add nodeparser test case
A serialized frame from the widget factory!
Timm Bäder [Wed, 24 Apr 2019 16:57:11 +0000 (18:57 +0200)]
ci: Don't disable the gsk suite
Timm Bäder [Wed, 24 Apr 2019 16:30:46 +0000 (18:30 +0200)]
Add error func to node deserialization
Benjamin Otte [Sat, 27 Apr 2019 05:20:20 +0000 (07:20 +0200)]
testsuite: Black out parts of reftest
Timm Bäder [Wed, 24 Apr 2019 11:50:04 +0000 (13:50 +0200)]
testsuite: Remove old cairo/vulkan tests
They are still in the old binary format and haven't worked for a while.
Timm Bäder [Wed, 24 Apr 2019 11:47:30 +0000 (13:47 +0200)]
rendernode: Remove old GVariant (de)serialization code
We're doing the CSS thing now.
Timm Bäder [Wed, 24 Apr 2019 11:25:32 +0000 (13:25 +0200)]
testsuite: Add another gl renderer test
Benjamin Otte [Sat, 27 Apr 2019 04:42:28 +0000 (06:42 +0200)]
testsuite: Remove gl_tests infrastructure
They're now completely migrated to the new compare infrastructure, that
also tests Vulkan and Cairo.
Timm Bäder [Wed, 24 Apr 2019 10:48:59 +0000 (12:48 +0200)]
testsuite: Add cross-fade-in-opacity test
Making sure that an opacity node doesn't end up reviving a node that's
hidden because the cross-fade has progress 0 or 1.
Timm Bäder [Wed, 24 Apr 2019 10:48:13 +0000 (12:48 +0200)]
testsuite: Remove broken GL comparison tests
These only work on special hardware, which not even I have anymore.
We'll need to redo them in a way that works on different systems.
Timm Bäder [Wed, 24 Apr 2019 09:26:34 +0000 (11:26 +0200)]
testsuite: Print serialized nodes when parsing fails
Timm Bäder [Wed, 24 Apr 2019 09:26:17 +0000 (11:26 +0200)]
testsuite: add shadow node parser test
Timm Bäder [Wed, 24 Apr 2019 08:49:36 +0000 (10:49 +0200)]
testsuite: add another nodeparser crash test
Timm Bäder [Tue, 23 Apr 2019 16:08:06 +0000 (18:08 +0200)]
testsuite: Add serialize-deserialize tests
Check that we can successfully deserialize a node, then serialize it
again and deserialize that result once more.
Benjamin Otte [Thu, 21 Mar 2019 05:47:36 +0000 (06:47 +0100)]
testsuite: Add a broken test
This also adds some build magic so all tests that contain "-3d" in them
won't be added to the Cairo renderer.
Of course, this new test is such a test.
Benjamin Otte [Tue, 19 Mar 2019 07:16:07 +0000 (08:16 +0100)]
Move working tests to new directory
These are tests that are working on both GL and Cairo now.
Some tests got black boxes over the areas that aren't easy to compare.
Timm Bäder [Sat, 2 Mar 2019 10:15:02 +0000 (11:15 +0100)]
testsuite: Port gl tests to text-based format
Benjamin Otte [Sat, 27 Apr 2019 01:27:30 +0000 (03:27 +0200)]
testsuite: Delete some node tests
These are the tests that aren't going to be made to work, so let's just
delete them.
Benjamin Otte [Tue, 19 Mar 2019 04:29:20 +0000 (05:29 +0100)]
testsuite: Add tests for the new node parsing code
This adds a test tool gsk/node-parser that takes node files and parses
them.
A few of these node files have been added, for crashes I encountered while
developing the new parsing code.
Timm Bäder [Sat, 2 Mar 2019 15:55:17 +0000 (16:55 +0100)]
Parse render nodes from text files
Instead of the previous approach using GVariant, this new approach uses
human-readable text files as the serialization format for render nodes.
The format is a custom one, but it is inspired by QML and conforms to
the CSS syntax. Because of that, we can use the CSS machinery from GTK
to parse it, and in particular share code to parse properties that GTK's
CSS machinery also supports, such as colors.
This commit breaks all existing usages of node files - such as the
testsuite and various test tools - they will be fixed in further
commits.
Benjamin Otte [Wed, 1 May 2019 13:27:52 +0000 (15:27 +0200)]
cssparser: Add gtk_css_parser_has_number()
Asier Sarasua Garmendia [Sat, 4 May 2019 19:34:25 +0000 (19:34 +0000)]
Update Basque translation
Matthias Clasen [Sat, 4 May 2019 18:51:27 +0000 (18:51 +0000)]
entry: Drop our own Emoji chooser
We were using one Emoji chooser when triggered
via the context menu, and another one when
triggered via the icon.
Change things to always use the same Emoji
chooser instance.
Matthias Clasen [Sat, 4 May 2019 15:18:35 +0000 (15:18 +0000)]
window: Stop duplicating focus change events
We had code in gtkwindow.c that generated duplicate,
and defective, focus-change events, in the following
way:
- gtkmain.c generates a chain of focus-change events
for moving focus from one window to another
- gtkwindow.c catches a focus-in event in the middle
of this chain and sets itself as 'active'
- and then it proceeds to generate focus-change
events towards its own focus widget without a
related target
This is not necessary since we gtkmain.c already
generates a complete sequence of focus-change events.
So stop doing it.
Matthias Clasen [Sat, 4 May 2019 15:06:40 +0000 (15:06 +0000)]
window: Make _gtk_window_set_is_active static
It is not used outside gtkwindow.c.
Matthias Clasen [Sat, 4 May 2019 15:58:11 +0000 (15:58 +0000)]
builder-tool: Handle GtkWidget::visible properly
This property has a 'smart' default that depends
on the class of the object we're creating. Take
that into account when deciding whether to omit
properties that are set to their default value.
Matthias Clasen [Sat, 4 May 2019 16:55:52 +0000 (16:55 +0000)]
emoji chooser: Make Escape work again
Escape is expected to close the Emoji chooser.
Matthias Clasen [Sat, 4 May 2019 16:19:43 +0000 (16:19 +0000)]
emoji chooser: Fix handling of no recent Emoji
If the recent section is empty, we want to hide
it, make its button insensitive, and select the
next section, initially. This was not working
properly, since nothing was ever setting the
section box to invisible.
Asier Sarasua Garmendia [Sat, 4 May 2019 09:54:08 +0000 (09:54 +0000)]
Update Basque translation
Mohammed Sadiq [Sat, 4 May 2019 09:39:35 +0000 (15:09 +0530)]
docs: fix typo in function name
Matthias Clasen [Sat, 4 May 2019 02:12:02 +0000 (02:12 +0000)]
emoji chooser: populate incrementally
It takes half a second on my system to initially
populate the Emoji chooser. That is too long. Do
the work in 8 millisecond chunks to give GTK a
chance to get some frames done.
Matthias Clasen [Fri, 3 May 2019 04:58:46 +0000 (04:58 +0000)]
docs: Add an actions overview
Add an introduction chapter explaining actions
in detail. Most of this content is taken from
the GAction HowDoI page.
Matthias Clasen [Fri, 3 May 2019 04:57:58 +0000 (04:57 +0000)]
docs: Some additions to the overview
Mention graphene and gsk.
Matthias Clasen [Fri, 3 May 2019 04:22:07 +0000 (04:22 +0000)]
docs: Some updates to the input overview
Remove references to no longer existing apis,
and reword some things. Say surface instead of
window. Start filling out the keyboard section.
Jordi Mas [Fri, 3 May 2019 18:54:07 +0000 (20:54 +0200)]
Update Catalan translation
Timm Bäder [Fri, 3 May 2019 06:15:27 +0000 (08:15 +0200)]
filechooserbutton: Clean up finalize & destroy